﻿using System;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;

namespace lifeofbob
{
    class Bullet : Projectile
    {
        static private Point size = new Point(8, 8);
        static private Texture2D texture = TextureLibrary.bullet;

        private float angle;

        public Bullet(Vector2 pos, Vector2 speed) : base (pos, size, speed, texture)
        {
            Random rand = new Random();
            angle = rand.Next(-1, 1);
        }

        public override void Draw(SpriteBatch sb)
        {
            sb.Draw(texture, rectangle, null, Color.White, angle, new Vector2(0, 0), SpriteEffects.None, 0);
        }
    }
}
